#{extends 'main.html' /} #{set title:'User Communities' /}
#{set 'moreScripts'} 

<script type="text/javascript" src="@{'/public/javascripts/jquery-latest.js'}"></script>
<script type="text/javascript" src="@{'/public/javascripts/jquery.tablesorter.js'}"></script>

<script type="text/javascript">
	$(function() {		
		$("#userCommunities").tablesorter({sortList:[[0,0],[2,1]], widgets: ['zebra']});
		$("#options").tablesorter({sortList: [[0,0]], headers: { 3:{sorter: false}, 4:{sorter: false}}});
	});	
	</script>
	#{/set}
<div id=main>
<br>
<br>
	 <h1>${user.name} related Communities page</h1>
	<br>
	<table id="userCommunities" cellpadding="8" class="tablesorter"  align="left">
		<thead>
					
						<tr>
							<th><u>Community Name</u></th>
							
						</tr>
</thead>
<tbody>
		#{list items:communityList, as:'Community'}
						<tr>
						<td>${Community.name}</td>
						</tr>

#{/list} #{else} Sorry!There are no any related communities any communities #{/else}
</tbody>
</table>
<div style="clear:both;"></div>
</div>
